/**
 * @author: zh
 * @date: 2021/12/17 23:28
 * @version: 1.0
 */
public abstract class Zh0202Enterprise {
    protected Zh0202Mediator mediator;
    protected String type;
    protected String name;

    public Zh0202Enterprise(String name) {
        this.name = name;
    }

    public Zh0202Mediator getMediator() {
        return mediator;
    }

    public void setMediator(Zh0202Mediator mediator) {
        this.mediator = mediator;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    /**
     * +   sendMsg(String to,String msg) : void
     * +   receiveMsg(String to,String msg) : void
     * +   response() : void
     */
    public void receiveMsg(String from, String msg) {
        System.out.println(this.name + "接收来自" + from + "的会议通知,内容是：" + msg);
    }

    public abstract void sendMsg(String to, String msg);

    public void reponse(){
        System.out.println(this.name+"收到！");
    }
}
